<?php
defined('BY_JYA') or exit('error');
$_RQ['op']=$_RQ['op']?$_RQ['op']:'basic';
$return=array();
/*******basic*******/
if($_RQ['op']=='basic'){
	if($_RQ['postdata']){
		$postdata=get_postdata();
		if(!$postdata['ordersn']){
			exi('请输入订单号！','error');
		}
		if(!$postdata['aliapp_id']){
			exi('请选择支付宝小程序！','error');
		}
		$this->model('model')->cancel_xinyong($postdata['ordersn'],$postdata['aliapp_id']);
		exi('操作成功');
	}
	$return['item']=array();
	$htmls=array(
		'type'=>'edit',
		'desc'=>'解除信用免押',
		'edit'=>array(
			array('type'=>'tip','title'=>'[温馨提示]：输入要解除信用免押的订单号
					'),
			array('type'=>'string','title'=>'订单号','name'=>'ordersn'),
			array('name'=>'aliapp_id','title'=>'选择支付宝小程序','type'=>'select','options'=>'wxapps'),
		),
	);
	$return['wxapps']=pdo_getall('core_account_wxapp',array('uniacid'=>$_SESSION['uniacid']),array('id','title'));
	$return['htmls']=$htmls;
	exi($return);
}
/*******basic*******/
/*******op*******/
